package com.rockywong.springcloud.controller;

import com.rockywong.springcloud.feign.IndexClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

/**
 * Created by rockywong on 2018/7/31.
 */
@RestController
public class IndexController {

    @Autowired
    private IndexClient client;

    @GetMapping("/feign/show")
    public String show() {
        String r = client.show();
        return r;
    }
}
